public class TestPolym {
    public static void main(String[] args) {
        animalCry(new Dog());
        animalCry(new Cat());
        Animal animal = new Dog();
        animal.shout();
        Dog d=(Dog)animal;
        d.shout();
//        Cat c=(Cat)animal;
//        c.catchMouse();
    }
    static void animalCry(Animal a){
        a.shout();

    }
}
